Repository navigation
Conversation
An application (context) gets a menu of items that each open a view, a table or a link. Items are loaded with the context in one chunked query, and an item whose view or table no longer exists is reported as broken, computed in SQL. Deleting an application deletes its menu. - a menu item's technical name is unique within its application, kept so by a unique index on (context_id, technical_name) - the item target type is typed as view, table or url in the API - the mapper groups the joined context rows in one place instead of three Co-authored-by: Ruben van der Linde <ruben@conduction.nl> Assisted-by: ClaudeCode:claude-opus-5-5 Signed-off-by: Remko <remko@conduction.nl>
…nu items - MenuItemMapperTest runs against a real database: items pointing at a deleted view or table come back broken and links never do, items are ordered and grouped per application, and ContextMapper::findById() and findAll() carry the menu - MenuItemTest serializes each of the three target types - technicalName is a string in the entity and the API: the column is not null Assisted-by: ClaudeCode:claude-opus-5-5 Signed-off-by: Remko <remko@conduction.nl>
49a3011 to
3369be5
Compare
3369be5 to
ecba0ec
Compare
|
Hello there, We hope that the review process is going smooth and is helpful for you. We want to ensure your pull request is reviewed to your satisfaction. If you have a moment, our community management team would very much appreciate your feedback on your experience with this PR review process. Your feedback is valuable to us as we continuously strive to improve our community developer experience. Please take a moment to complete our short survey by clicking on the following link: https://cloud.nextcloud.com/apps/forms/s/i9Ago4EQRZ7TWxjfmeEpPkf6 Thank you for contributing to Nextcloud and we hope to hear from you soon! (If you believe you should not receive this message, you can add yourself to the blocklist.) |
|
Closing this in favour of the new stack that starts at #3131. After the review on #3075, @enjeck's design in #3099 and #3100 replaced the model these PRs were built on, so they can't be updated in place. The backend of grid pages and application menus is now in #3131 to #3138. The frontend follows in separate PRs. @remko48 is co-author on the menu commits there. Thanks to everyone who reviewed these. |
Applications (contexts) get a menu: an ordered list of items that each open a view, a table or a web link. This PR adds the data model and returns the menu with the application; saving it comes in the next PR.
What changes
tables_contexts_menu_item(label, icon, target type + id or url, technical name, order). Every item has a technical name, unique within one application, enforced by a unique index.MenuItementity +MenuItemMapper: the menus of all requested applications are loaded in one query (chunked for Oracle), not one per application.broken: true, worked out in the same query, so the UI can show it and the owner can fix it.ContextMapper: the three copies of the "group joined rows per context" code are replaced by oneformatResultSet(). The navigation bar query skips loading menus, since it doesn't show them; theremenuItemsis always empty.menuItemsis added to the context response (OpenAPI and TS types regenerated).🖼️ Screenshots
Backend only, no UI changes.
🏁 Checklist
/backport to stableX.X🤖 AI (if applicable)